<% title "#{@config_report.host}"%>
<% breadcrumbs(switchable: false) %>

<p class='ra'> <%= _("Reported at %s ") % @config_report.reported_at %> </p>
<% if @offset > 10 %>
  <%= alert :class => 'alert-danger',
    :header => _('Host times seem to be adrift!'),
    :text => "</br>".html_safe + (_("Host reported time is <em>%s</em>") % @config_report.reported_at).html_safe + "</br>".html_safe +
             (_("Foreman report creation time is <em>%s</em>") % @config_report.created_at).html_safe + "</br>".html_safe +
             (_("Which is an offset of <b>%s</b>") % distance_of_time_in_words(@config_report.reported_at, @config_report.created_at, :include_seconds => true)).html_safe %>
<% end %>

<% content_for(:search_bar) {logs_show} %>

<%= render report_origin_output_partial(@config_report.origin), :logs => @config_report.logs %>
<%= render 'metrics', :status => @config_report.status, :metrics => @config_report.metrics["time"] if @config_report.metrics["time"] %>

<%= title_actions display_delete_if_authorized(hash_for_config_report_path(:id => @config_report), :class=> "btn btn-danger"),
  link_to(_("Host details"), current_host_details_path(@config_report.host), :class => 'btn btn-default'),
  link_to(_("Other reports for this host"), host_config_reports_path(@config_report.host), :class => 'btn btn-default')
%>

<%= react_component('DiffModal') %>
